var arr=[1,2,3,53,1,4,12,13,1,3,5];
var m=new Map();
arr.forEach((v)=>{
    if(m.has(v)){
        m.set(v,m.get(v)+1);
    }else{
        m.set(v,1)
    }
})
console.log(m);
let maxLength=0;
let maxValue;
for(let max of m){
    if(max[1]>maxLength){
        maxLength=max[1];
        maxValue=max[0];
    }
}
console.log(maxValue);